package gecko.model;

import gecko.view.swing.GESTION.VGestionAjout;
import javax.swing.JFileChooser;

public class ImporterPDF {
	static JFileChooser choix = new JFileChooser();
	static String url = null;
	
	public static String importer(){
		int retour=choix.showOpenDialog(VGestionAjout.lCorps);

		if(retour==JFileChooser.APPROVE_OPTION){
			url = choix.getSelectedFile().getAbsolutePath();				
		} else if(retour==JFileChooser.CANCEL_OPTION){ 
			url = null;
		}
		return url;	
	}

	public static String getUrl() {
		return url;
	}

	public static void setUrl(String url) {
		ImporterPDF.url = url;
	}
	
	
}
